import request from '@/utils/request'

export function fetchList(data) {
  return request({
    url: '/cloud-system/getObjectDefineList',
    method: 'post',
    data
  })
}

export function fetchOne(data) {
  return request({
    url: '/cloud-system/getOneObjectDefineDetail',
    method: 'post',
    data
  })
}

export function createObjectdefine(data) {
  return request({
    url: '/cloud-system/createOneObjectDefine',
    method: 'post',
    data
  })
}

export function updateObjectDefine(data) {
  return request({
    url: '/cloud-system/updateOneObjectDefine',
    method: 'post',
    data
  })
}

export function deleteObjectDefine(data) {
  return request({
    url: '/cloud-system/deleteOneObjectDefine',
    method: 'post',
    data
  })
}

export function lockObjectDefine(data) {
  return request({
    url: '/cloud-system/lockOneObjectDefine',
    method: 'post',
    data
  })
}

export function unlockObjectDefine(data) {
  return request({
    url: '/cloud-system/unlockOneObjectDefine',
    method: 'post',
    data
  })
}

export function batchLockObjectDefine(data) {
  return request({
    url: '/cloud-system/batchLockObjectDefine',
    method: 'post',
    data
  })
}

export function batchUnLockObjectDefine(data) {
  return request({
    url: '/cloud-system/batchUnLockObjectDefine',
    method: 'post',
    data
  })
}

export function batchDeleteObjectDefine(data) {
  return request({
    url: '/cloud-system/batchDeleteObjectDefine',
    method: 'post',
    data
  })
}

export function getTableFieldList(data) {
  return request({
    url: '/cloud-system/getTableFieldList',
    method: 'post',
    data
  })
}
export function updateTableField(data) {
  return request({
    url: '/cloud-system/updateTableField',
    method: 'post',
    data
  })
}